A function parameter, used within the stack of arguments. More...
Public Member Functions | |
FunctionParameter () | |
FunctionParameter (bool val) | |
FunctionParameter (int val) | |
FunctionParameter (float val) | |
FunctionParameter (double val) | |
FunctionParameter (const char *val) | |
FunctionParameter (const nkMemory::StringView &val) | |
FunctionParameter (void *val, const nkMemory::StringView &userTypeName, bool scriptOwner) | |
FunctionParameter (const ScriptObjectReference &scriptObjectReference) | |
FunctionParameter (const FunctionParameter &other) | |
~FunctionParameter () | |
void | prepareForInternalType () |
void | prepareForString () |
void | prepareForUserType () |
void | prepareForScriptObjectReference () |
FunctionParameter & | operator= (const FunctionParameter &other) |
Public Attributes | |
union { | |
bool _valBool | |
int _valInt | |
float _valFloat | |
double _valDouble | |
nkMemory::String _valString | |
UserTypeHolder _valUser | |
ScriptObjectReference _valScriptObject | |
}; | |
FUNCTION_PARAMETER_TYPE | _type |
The actual type of the variable held. | |
Static Public Attributes | |
static FunctionParameter | VOID |
A function parameter, used within the stack of arguments.
nkScripts::FunctionParameter::FunctionParameter | ( | ) |
Default constructor.
|
explicit |
Specific constructor.
val | The value to assign. |
|
explicit |
Specific constructor.
val | The value to assign. |
|
explicit |
Specific constructor.
val | The value to assign. |
|
explicit |
Specific constructor.
val | The value to assign. |
nkScripts::FunctionParameter::FunctionParameter | ( | const char * | val | ) |
Specific constructor.
val | The value to assign. |
nkScripts::FunctionParameter::FunctionParameter | ( | const nkMemory::StringView & | val | ) |
Specific constructor.
val | The value to assign. |
nkScripts::FunctionParameter::FunctionParameter | ( | void * | val, |
const nkMemory::StringView & | userTypeName, | ||
bool | scriptOwner | ||
) |
Specific constructor.
val | The value to assign. |
userTypeName | The user type name of the object set. |
scriptOwner | Whether the script is the owner of given object and should delete it upon garbage collection. |
nkScripts::FunctionParameter::FunctionParameter | ( | const ScriptObjectReference & | scriptObjectReference | ) |
Specific constructor.
scriptObjectReference | The reference to assign. |
nkScripts::FunctionParameter::FunctionParameter | ( | const FunctionParameter & | other | ) |
Copy constructor.
other | The parameter to copy. |
nkScripts::FunctionParameter::~FunctionParameter | ( | ) |
Destructor.
void nkScripts::FunctionParameter::prepareForInternalType | ( | ) |
Prepares internal memory layout for the type given.
void nkScripts::FunctionParameter::prepareForString | ( | ) |
Prepares internal memory layout for the type given.
void nkScripts::FunctionParameter::prepareForUserType | ( | ) |
Prepares internal memory layout for the type given.
void nkScripts::FunctionParameter::prepareForScriptObjectReference | ( | ) |
Prepares internal memory layout for the type given.
FunctionParameter& nkScripts::FunctionParameter::operator= | ( | const FunctionParameter & | other | ) |
Copy operator.
other | The parameter to copy. |
union { ... } |
Union of all types possible to have.
|
static |
Static parameter enabling a quick void parameter use.